// Copyright 2023 Huawei Cloud Computing Technology Co., Ltd.
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
// You may obtain a copy of the License at
//
//     http://www.apache.org/licenses/LICENSE-2.0
//
// Unless required by applicable law or agreed to in writing, software
// distributed under the License is distributed on an "AS IS" BASIS,
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
// See the License for the specific language governing permissions and
// limitations under the License.

export const DECODER_TYPE_MAP = {
    'H264': 0,
    'H265': 1
}
export const MOBILE_CAMERA_MODE_MAP = {
    1: 'user', // 前置
    0: 'environment' // 后置
}
export const CAMERA_COMMON_MODE_MAP = {
    'USER': 1, // 前置
    'ENVIRONMENT': 0 // 后置
}
export const FRAME_TYPE_MAP = {
    'TYPE265': 'h265',
    'TYPE264': 'h264'
}
// 后续CAE优化后，从CAE获取云手机宽高比
export const CLOUD_PHONE_RATIO = 9/16;

export const PACKAGE_HEADER_LENGTH = 8;
// 媒体类req消息头长度
export const MEDIA_MSG_HEADER_COUNT = 16;
// 相机rsp长度
export const CAMERA_RSP_LEN = MEDIA_MSG_HEADER_COUNT + 2;
// 麦克风rsp长度
export const MICROPHONE_RSP_LEN = MEDIA_MSG_HEADER_COUNT + 2;
// 麦克风音频流rsp长度
export const MIC_START_RECORD_RSP_LEN = MEDIA_MSG_HEADER_COUNT + 4;
// pc场景摄像头最大高度
export const PC_CAMERA_MAX_HEIGHT = 720;
// 默认画质
export const DEFAULT_DEFINITION = 'HD';
// 设备旋转角度
export const DEVICE_ORIENTATION_ANGLES = {
    'PORTRAIT': 0,
    'REVERSE_PORTRAIT': 180,
    'LANDSCAPE': 90,
    'REVERSE_LANDSCAPE': 270
};
